<?php
include('/var/www/html/new/d/module/api/function.class.php');
$PFT_infunction = new AllFunction();

if (!class_exists("go_sql")){
	include("/var/www/html/new/conf/le.je");
	$le=new go_sql();
	$le->connect();
}

$Ordern = $_REQUEST['Ordern'] + 0;
if(!$Ordern)	exit("请传入订单号");
$pft_order_xml = $PFT_infunction->Select_PFTorder($_REQUEST['Ordern']);
$ordernum = (string)$pft_order_xml->Rec->UUordernum;
$lid = (string)$pft_order_xml->Rec->UUlid;
if($lid != 7641) exit("不是青岛所属订单");
$UUstatus = (int)$pft_order_xml->Rec->UUstatus;
if($UUstatus != 0 ) exit("订单不是未使用状态，不能重发");
$tid = (string)$pft_order_xml->Rec->UUtid;
$aid = (string)$pft_order_xml->Rec->UUaid;
$fid = (string)$pft_order_xml->Rec->UUbuyid;
$pid = (string)$pft_order_xml->Rec->UUpid;
$title = (string)$pft_order_xml->Rec->UUltitle.(string)$pft_order_xml->Rec->UUttitle;
$tnum = (int)$pft_order_xml->Rec->UUtnum;
$begintime = (string)$pft_order_xml->Rec->UUbegintime;
$vcode = (string)$pft_order_xml->Rec->UUvcode;
$tordernum = (string)$pft_order_xml->Rec->UUtordernum;
$tel = (string)$pft_order_xml->Rec->UUordertel;
$sms = $PFT_infunction->HQ_send_sms($tel,$aid,$fid,$tid,$pid,$ordernum,$lid,$title,$tnum,$begintime,$vcode);
if($sms == 100)  echo "重发短信成功！";
else echo "重发短信失败！";
echo "<br/>";
exit("入园码是：".$vcode);
?>
